X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/76aea3697c6043c1613370f172395b4f65ee71f0..2376fb745f4ae8c6bd2353127524e0b28005143d:/wp-admin/media.php?action=edit;attachment_id=%3C%3Fphp%20echo%20%24post-%3EID;%20%3F%3E= diff --git a/wp-admin/media.php b/wp-admin/media.php index 150dea75..6715773b 100644 --- a/wp-admin/media.php +++ b/wp-admin/media.php @@ -1,8 +1,15 @@ ID) ) wp_die( __('You attempted to edit an attachment that doesn’t exist. Perhaps it was deleted?') ); + if ( $att->post_status == 'trash' ) wp_die( __('You can’t edit this attachment because it is in the Trash. Please move it out of the Trash and try again.') ); + add_filter('attachment_fields_to_edit', 'media_single_attachment_fields_to_edit', 10, 2); wp_enqueue_script( 'wp-ajax-response' ); - wp_admin_css( 'media' ); - + wp_enqueue_script('image-edit'); + wp_enqueue_style('imgareaselect'); - require( 'admin-header.php' ); + require( './admin-header.php' ); + $parent_file = 'upload.php'; $message = ''; $class = ''; if ( isset($_GET['message']) ) { switch ( $_GET['message'] ) : case 'updated' : $message = __('Media attachment updated.'); - $class = 'updated fade'; + $class = 'updated'; break; endswitch; } @@ -81,20 +86,24 @@ case 'edit' : ?>
- +

-
-
+ +

+ +

+ +
- false, 'send' => false, 'delete' => false, 'errors' => $errors ) ); ?> + false, 'send' => false, 'delete' => false, 'show_title' => false, 'errors' => $errors ) ); ?>

- - - + + + @@ -105,7 +114,7 @@ case 'edit' :